home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-01 / wlib11_2.zip / EXAMPLES.EXE / EXAM55.C < prev    next >
C/C++ Source or Header  |  1991-03-13  |  851b  |  24 lines

  1.   #include "window.h"
  2.   #include <string.h>
  3.   #define NORM    CREATE_VIDEO_ATTRIBUTE(black,white)
  4.   #define REVERSE CREATE_VIDEO_ATTRIBUTE(white,black)
  5.   #define CREDITCARDMASK "____-____-____-____"
  6.  
  7.   WPOINTER w;
  8.   char buffer[80];
  9.   main()
  10.   {
  11.     int i,row,col;
  12.     buffer[0] = 0;   /* Make sure first character is null */
  13.     WindowInitializeSystem();
  14.     WindowSaveInitial(0);
  15.     w = WindowInitialize(BORDER,1,1,40,10,NORM,NORM,SINGLEBOX);
  16.     WindowOpen(w);
  17.     WindowDisplay(w,1,NOEFFECT);
  18.     buffer[0] = 0;   /* Make sure first character is null */
  19.     WindowWriteString(w,"Enter A Password",1,1);
  20.     WindowGetMaskPasswordAttr(w,2,1,buffer,CREDITCARDMASK,' ','*',0,40,0,
  21.                               REVERSE, "40.");
  22.     WindowWriteString(w,"You entered the following:",3,1);
  23.     WindowWriteString(w,buffer,4,1);
  24.   }